home *** CD-ROM | disk | FTP | other *** search
/ Gekikoh Dennoh Club 1 / Gekikoh Dennoh Club Vol. 1 (Japan).7z / Gekikoh Dennoh Club Vol. 1 (Japan) (Track 1).bin / kowin / archive / apl / gview120.lzh / gviewsrc.lzh / gramget.c < prev    next >
C/C++ Source or Header  |  1995-02-13  |  691b  |  36 lines

  1. /*
  2.     Copyright 1995 Ogasawara Hiroyuki(COR.)
  3. */
  4.  
  5. #include    <corlib.h>
  6. #include    <sys_doslib.h>
  7. #include    "gview.h"
  8.  
  9. void
  10. GV_VramToBuf( gp )
  11. GVIEW    *gp;
  12. {
  13.     int    sp;
  14.     if(1); sp= SUPER(0); if(1);
  15.     {
  16.         unsigned short    *vp= (void*)0xc00000;
  17.         int    x, y;
  18.         if( gp->color == WindowAttrGraphic65536 ){
  19.             unsigned short    *str= gp->buf;
  20.             for( y= 0 ; y< gp->v ; y++ ){
  21.                 for( x= 0 ; x < gp->h ; x++ )
  22.                     *str++= vp[y*512+x];
  23.             }
  24.         }else{
  25.             unsigned char    *str= (void*)gp->buf;
  26.             int    xlen= gp->color==WindowAttrGraphic16?1024:512;
  27.             for( y= 0 ; y< gp->v ; y++ ){
  28.                 for( x= 0 ; x < gp->h ; x++ )
  29.                     *str++= vp[y*xlen+x];
  30.             }
  31.         }
  32.     }
  33.     if(1); SUPER( sp ); if(1);
  34. }
  35.  
  36.